<%@page language="java" pageEncoding="UTF-8" contentType="text/html;charset=utf-8"%>
<%@include file="/includes/taglibs.jsp"%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
            
    <script type="text/javascript">
    <!-- 
    $(document).ready(function() {
    	$("#doQueryBtn").click(function() {
			$("#hidden\\.doQueryBtn").trigger('click');
		});
    });
       
    function doPrintEvent()
    {
    	divPrint('queryForm');
    	return false;
    }
    
    //-->
    </script>
</head>
<body>
	
	<div id="smallQueryForm"></div>

	<div id="queryForm">
		<table>
			<tr>
				<td colspan="5" class="queryHeader">上傳紀錄</td>
			</tr>
			<tr>
				<th>上傳時間</th>
				<td colspan="4" ><fmt:formatDate value="${actionBean.viewUploadFile.uploadDate}" pattern="yyyy/MM/dd HH:mm:ss" /></td>
			</tr>
			<tr>
				<th>上傳類別</th>
				<td colspan="4"><c:out value="${actionBean.viewUploadFile.fileFormatName }" /></td>
			</tr>
			<tr>
				<th>檔案名稱</th>
				<td colspan="4"><c:out value="${actionBean.viewUploadFile.fileName }" /> </td>
			</tr>
			<tr>
				<th>上傳經辦</th>
				<td colspan="4"><c:out value="${actionBean.viewUploadFile.uploadUser.userName }" /></td>
			</tr>
			<tr>
				<th>上傳結果</th>
				<td colspan="4"><c:out value="${actionBean.viewUploadFile.fileStatusName }" /></td>
			</tr>
			<tr>
				<th>上傳歷程</th>
				<td>
				   <c:forEach items="${actionBean.qryUploadFileActionLog}" var="viewObj" varStatus="rowstat">
                   
					     <fmt:formatDate value="${viewObj.actionTime}" pattern="yyyy/MM/dd" />
                         <fmt:formatDate value="${viewObj.actionTime}" pattern="HH:mm:ss" />
                         <c:out value="${viewObj.user.userName }" />
						 <c:out value="${viewObj.actionName }" /><br/>                              
                    
                    </c:forEach>
				</td>
			</tr>
			<tr>
				<td colspan="5" class="queryFunction">
					<input type="button" id="doQueryBtn" name="doQuery" value="確認" class="formBtn"/>
                	<input type="button" value="列印" onclick="javascript:doPrintEvent();" class="formBtn"/>
                </td>

			</tr>
		</table>
	</div>

	
	<div id="listForm"></div>

<div style="display: none;">
<stripes:form id="hidden.queryUploadFileFrom" beanclass="com.feib.stms.action.Stms9003ActionBean" method="post" onsubmit="javascript: waitingDialog({});">
	<stripes:hidden id="hidden.qryUploaddDateFrom" name="qryUploaddDateFrom" formatPattern="yyyy/MM/dd"/>
	<stripes:hidden id="hidden.qryUploadDateHourFrom" name="qryUploadDateHourFrom" />
	<stripes:hidden id="hidden.qryUploadDateTo" name="qryUploadDateTo" formatPattern="yyyy/MM/dd" />
	<stripes:hidden id="hidden.qryUploadDateHourTo" name="qryUploadDateHourTo" />
	<stripes:hidden id="hidden.qryUploadUserId" name="qryUploadUserId" />
	<c:forEach items="${actionBean.uploadFileFormats}" var="uploadFileFormatObj" varStatus="rowstat">
		<stripes:checkbox id="hidden.qryFileFormats[${rowstat.index}]" name="qryFileFormats[${rowstat.index}]" value="${uploadFileFormatObj.value}"/>
	</c:forEach>
	
	<stripes:hidden id="qryUploadFile.group.groupNo" name="qryUploadFile.group.groupNo" />
	<stripes:hidden id="qryUploadFile.group.groupPk" name="qryUploadFile.group.groupPk" />
	
	
	<stripes:hidden id="hidden.queryResult.pageNumber" name="queryResult.pageNumber" />
	<stripes:hidden id="hidden.queryResult.sortCriterion" name="queryResult.sortCriterion" />
	<stripes:hidden id="hidden.queryResult.sortDirection" name="queryResult.sortDirection" />
	<stripes:hidden id="hidden.qryUploadFilePk" name="qryUploadFilePk" />
	<stripes:submit id="hidden.doQueryBtn" name="doQuery" value="查詢" class="formBtn"/>
	<stripes:submit id="hidden.doViewDetailBtn" name="doViewDetail" value="明細" class="formBtn"/>
</stripes:form>
</div>

</body>
</html>
